package com.arpa.wms.domain.vo;

import com.alibaba.fastjson.annotation.JSONField;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;
import org.hibernate.validator.constraints.Length;

import java.io.Serializable;
import java.math.BigDecimal;
import java.time.LocalDateTime;
import java.util.ArrayList;
import java.util.List;

/**
 * <p>
 * 移位DTO
 * </p>
 *
 * @author LEO
 * @since 2020-08-24
 */
@Data
@ApiModel(value="MoveVO对象", description="移位")
public class MoveVO implements Serializable {

    @ApiModelProperty(value = "移位单号")
    private String code;

    @ApiModelProperty(value = "仓库")
    private String warehouseCode;
    @ApiModelProperty(value = "所属机构Code")
    private String groupCode;

    @ApiModelProperty(value = "下发状态:0未下发，1已下发；")
    private Integer issue;

    @ApiModelProperty(value = "总数量")
    private BigDecimal totalQuantity;

    @ApiModelProperty(value = "状态")
    private String status;
    @ApiModelProperty(value = "审核意见")
    private String auditMind;
    @ApiModelProperty(value = "备注")
    @Length(max = 100, message = "备注长度不能大于100个字符", groups = {Save.class, Update.class})
    private String remarks;
    @ApiModelProperty(value = "仓库名称")
    private String warehouseName;

    @ApiModelProperty(value = "总数")
    private Long total;

    /**
     * 创建人
     */
    @ApiModelProperty(hidden = true)
    private String createdBy;

    /**
     * 修改人
     */
    @ApiModelProperty(hidden = true)
    private String modifiedBy;

    @ApiModelProperty(value = "创建时间")
    @JSONField(format = "yyyy-MM-dd HH:mm:ss")
    private LocalDateTime gmtCreated;

    @ApiModelProperty(value = "创建人")
    private String createdName;

    @ApiModelProperty(value = "修改人")
    private String modifiedName;

    @ApiModelProperty(value = "修改时间")
    @JSONField(format = "yyyy-MM-dd HH:mm:ss")
    private LocalDateTime gmtModified;

    @ApiModelProperty(value = "明细")
    private List<MoveItemVO> moveItemVOList = new ArrayList<>();

    @ApiModelProperty(value = "明细登记")
    private List<MoveRegisterVO> moveRegisterVOList = new ArrayList<>();

    @ApiModelProperty(value = "所属机构名称")
    private String groupName;
    public interface Save{}
    public interface Update{}
}
